import request from '@/utils/request'
export function getAdminUserPage(search) {
  return request({
    // url:'http://localhost:51905/api/RoleDbManager/GetPageList'
    url: '/api/AdminUserManager/GetPageList',
    method: 'post',
    data: search
  })
}

export function validateUserName(userName) {
  return request({
    url: '/api/AdminUserManager/ValidateUserName',
    method: 'get',
    params: { userName: userName }
  })
}
export function getAdminUserByUserName(userName) {
  return request({
    // url:'http://localhost:51905/api/RoleDbManager/GetPageList'
    url: '/api/AdminUserManager/GetAdminUserByUserName?userName=' + userName,
    method: 'post',
    data: userName
  })
}

export function adminUserAdd(userInfo) {
  return request({
    url: '/api/AdminUserManager/AdminUserAdd',
    method: 'post',
    data: userInfo
  })
}
export function adminUserUpdate(userInfo) {
  return request({
    url: '/api/AdminUserManager/AdminUserUpdate',
    method: 'post',
    data: userInfo
  })
}
